package io.chenglicun.modules.data.controller.statistics;

import io.chenglicun.common.annotation.LogOperation;
import io.chenglicun.common.constant.Constant;
import io.chenglicun.common.page.PageData;
import io.chenglicun.common.utils.ExcelUtils;
import io.chenglicun.common.utils.Result;
import io.chenglicun.common.validator.AssertUtils;
import io.chenglicun.common.validator.ValidatorUtils;
import io.chenglicun.common.validator.group.AddGroup;
import io.chenglicun.common.validator.group.DefaultGroup;
import io.chenglicun.common.validator.group.UpdateGroup;
import io.chenglicun.modules.data.dto.statistics.DataTimeStatisticsDTO;
import io.chenglicun.modules.data.dto.statistics.DataTotalStatisticsDTO;
import io.chenglicun.modules.data.excel.statistics.DataDayStatisticsExcel;
import io.chenglicun.modules.data.param.DataDayStatisticsParam;
import io.chenglicun.modules.data.service.statistics.DataDayStatisticsService;
import io.chenglicun.modules.data.service.statistics.impl.DataTotalStatisticsServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.simpleframework.xml.core.Validate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import springfox.documentation.annotations.ApiIgnore;

import javax.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Map;


/**
* 获取总数据
*
* @author pipi 1151485299@qq.com
* @since 1.0 2024-03-01
*/
@RestController
@RequestMapping("data/dataTotalstatistics")
@Api(tags="总统计数据")
public class DataTotalStatisticsController {

    @Autowired
    private DataTotalStatisticsServiceImpl dataTotalStatisticsService;
    @GetMapping("total")
    @ApiOperation("总数据获取")
    @RequiresPermissions("data:datadaystatistics:info")
    public Result<List<DataTotalStatisticsDTO>> list(){
        List<DataTotalStatisticsDTO> total = dataTotalStatisticsService.getTotal();
        return new Result<List<DataTotalStatisticsDTO>>().ok(total);
    }


}